#!/bin/sh
PIDPROC=`ps -ef | grep 'io.renren.RenrenApplication' | grep -v 'grep'| awk '{print $2}'`
if [ -z "$PIDPROC" ];then
 PRG="$0"
 PRGDIR=`dirname "$PRG"`
 cd $PRGDIR
 sh qy-admin.sh &
 PIDPROC=`ps -ef | grep 'io.renren.RenrenApplication' | grep -v 'grep'| awk '{print $2}'`
 echo $PIDPROC
else
 echo "qy-admin(pid:$PIDPROC) is running"
fi